package com.admin.utils;

import com.admin.es.entity.EsSchoolActivityEntity;
import com.admin.user.entity.SchoolActivity;

/**
 * 学校活动管理实体转es实体工具类
 * @author 武佳敏
 * @date 2023-02-01
 */
public class DataTransitionUtils {

    public static EsSchoolActivityEntity EntityToEsEntity(SchoolActivity schoolActivity){
        EsSchoolActivityEntity entity=new EsSchoolActivityEntity();
        entity.setId(schoolActivity.getId());
        entity.setSchoolName(schoolActivity.getSchoolName());
        entity.setParticipant(schoolActivity.getParticipant());
        entity.setPrincipal(schoolActivity.getPrincipal());
        entity.setActivityAddress(schoolActivity.getActivityAddress());
        entity.setActivityName(schoolActivity.getActivityName());
        entity.setIssueStatus(schoolActivity.getIssueStatus());
        entity.setPrincipalPhone(schoolActivity.getPrincipalPhone());
        return entity;
    }

}
